﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="ApplyCarForm.aspx.cs" Inherits="YhmOA.Integrated.Car.ApplyCarForm" %>

<%@ Register Assembly="DevExpress.Web.ASPxEditors.v10.1, Version=10.1.6.0, Culture=neutral, PublicKeyToken=c6bed6029ccaee5e"
    Namespace="DevExpress.Web.ASPxEditors" TagPrefix="dx" %>
<%@ Register Assembly="DevExpress.Web.v10.1, Version=10.1.6.0, Culture=neutral, PublicKeyToken=c6bed6029ccaee5e"
    Namespace="DevExpress.Web.ASPxCallback" TagPrefix="dx" %>
<%@ Register Assembly="DevExpress.Web.v10.1, Version=10.1.6.0, Culture=neutral, PublicKeyToken=c6bed6029ccaee5e"
    Namespace="DevExpress.Web.ASPxLoadingPanel" TagPrefix="dx" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head id="Head1" runat="server">
    <title>添加Integrated_Car_ApplyCar</title>
    <link type="text/css" rel="Stylesheet" href="../../Styles/Common.css" />
    <script type="text/javascript" src="../../Scripts/jquery-1.4.1.min.js"></script>
    <script type="text/javascript" src="../../Scripts/Common.js"></script>
    <script src="../../Scripts/DevEx.js" type="text/javascript"></script>
</head>
<body>
    <form id="form1" runat="server">
    <div class="MainRound">
        <div class="MainRoundContent">
            <div class="MainRoundContentW">
                <div class="MainBody">
                    <table class="Table" style="width: 740px">
                        <tr>
                            <th colspan="4" style="height: 40px;">
                                添加Integrated_Car_ApplyCar
                            </th>
                        </tr>
                        <tr>
                            <td style="width: 120px">
                                归还时间：
                            </td>
                            <td style="width: 250px">
                                <dx:ASPxDateEdit ID="txt_ReturnTime" ClientInstanceName="deReturnTimeCtrl" runat="server"
                                    TabIndex="0" NullText="请选择归还时间" Width="200px" Spacing="0">
                                    <ValidationSettings ErrorDisplayMode="ImageWithTooltip" RequiredField-ErrorText="请选择归还时间"
                                        ErrorFrameStyle-CssClass="TableNoBorder">
                                        <RequiredField IsRequired="True" />
                                    </ValidationSettings>
                                    <NullTextStyle ForeColor="LightSteelBlue" />
                                </dx:ASPxDateEdit>
                            </td>
                            <td style="width: 120px">
                                审批状态：
                            </td>
                            <td style="width: 250px">
                                <dx:ASPxTextBox ID="txt_ApproveStatus" ClientInstanceName="tbxApproveStatusCtrl"
                                    runat="server" MaxLength="50" NullText="请输入审批状态" TabIndex="1" Width="200px">
                                    <ValidationSettings ErrorDisplayMode="ImageWithTooltip" RequiredField-ErrorText="请输入审批状态"
                                        ErrorFrameStyle-CssClass="TableNoBorder">
                                        <RequiredField IsRequired="True" />
                                    </ValidationSettings>
                                    <NullTextStyle ForeColor="LightSteelBlue" />
                                </dx:ASPxTextBox>
                            </td>
                        </tr>
                        <tr>
                            <td style="width: 120px">
                                审批人：
                            </td>
                            <td style="width: 250px">
                                <dx:ASPxTextBox ID="txt_Approver" ClientInstanceName="tbxApproverCtrl" runat="server"
                                    MaxLength="50" NullText="请输入审批人" TabIndex="2" Width="200px">
                                    <ValidationSettings ErrorDisplayMode="ImageWithTooltip" RequiredField-ErrorText="请输入审批人"
                                        ErrorFrameStyle-CssClass="TableNoBorder">
                                        <RequiredField IsRequired="True" />
                                    </ValidationSettings>
                                    <NullTextStyle ForeColor="LightSteelBlue" />
                                </dx:ASPxTextBox>
                            </td>
                            <td style="width: 120px">
                                审批时间：
                            </td>
                            <td style="width: 250px">
                                <dx:ASPxDateEdit ID="txt_ApproveTime" ClientInstanceName="deApproveTimeCtrl" runat="server"
                                    TabIndex="3" NullText="请选择审批时间" Width="200px" Spacing="0">
                                    <ValidationSettings ErrorDisplayMode="ImageWithTooltip" RequiredField-ErrorText="请选择审批时间"
                                        ErrorFrameStyle-CssClass="TableNoBorder">
                                        <RequiredField IsRequired="True" />
                                    </ValidationSettings>
                                    <NullTextStyle ForeColor="LightSteelBlue" />
                                </dx:ASPxDateEdit>
                            </td>
                        </tr>
                        <tr>
                            <td style="width: 120px">
                                是否已归还:0,未归还;1:已归还：
                            </td>
                            <td style="width: 250px">
                                <dx:ASPxTextBox ID="txt_IsReturn" ClientInstanceName="tbxIsReturnCtrl" runat="server"
                                    MaxLength="4" NullText="请输入是否已归还:0,未归还;1:已归还" TabIndex="4" Width="200px">
                                    <ValidationSettings ErrorDisplayMode="ImageWithTooltip" RequiredField-ErrorText="请输入是否已归还:0,未归还;1:已归还"
                                        ErrorFrameStyle-CssClass="TableNoBorder">
                                        <RequiredField IsRequired="True" />
                                        <RegularExpression ErrorText="只能输入非负数字" ValidationExpression="^\d+(\.\d+)?$" />
                                    </ValidationSettings>
                                    <NullTextStyle ForeColor="LightSteelBlue" />
                                </dx:ASPxTextBox>
                            </td>
                            <td style="width: 120px">
                                出车时里程：
                            </td>
                            <td style="width: 250px">
                                <dx:ASPxTextBox ID="txt_SendMileage" ClientInstanceName="tbxSendMileageCtrl" runat="server"
                                    MaxLength="9" NullText="请输入出车时里程" TabIndex="5" Width="200px">
                                    <ValidationSettings ErrorDisplayMode="ImageWithTooltip" RequiredField-ErrorText="请输入出车时里程"
                                        ErrorFrameStyle-CssClass="TableNoBorder">
                                        <RequiredField IsRequired="True" />
                                        <RegularExpression ErrorText="只能输入正整数" ValidationExpression="^\+?[1-9][0-9]*$" />
                                    </ValidationSettings>
                                    <NullTextStyle ForeColor="LightSteelBlue" />
                                </dx:ASPxTextBox>
                            </td>
                        </tr>
                        <tr>
                            <td style="width: 120px">
                                归还时里程：
                            </td>
                            <td style="width: 250px">
                                <dx:ASPxTextBox ID="txt_ReturnMileage" ClientInstanceName="tbxReturnMileageCtrl"
                                    runat="server" MaxLength="9" NullText="请输入归还时里程" TabIndex="6" Width="200px">
                                    <ValidationSettings ErrorDisplayMode="ImageWithTooltip" RequiredField-ErrorText="请输入归还时里程"
                                        ErrorFrameStyle-CssClass="TableNoBorder">
                                        <RequiredField IsRequired="True" />
                                        <RegularExpression ErrorText="只能输入正整数" ValidationExpression="^\+?[1-9][0-9]*$" />
                                    </ValidationSettings>
                                    <NullTextStyle ForeColor="LightSteelBlue" />
                                </dx:ASPxTextBox>
                            </td>
                            <td style="width: 120px">
                                本次行驶里程：
                            </td>
                            <td style="width: 250px">
                                <dx:ASPxTextBox ID="txt_CurrentMileage" ClientInstanceName="tbxCurrentMileageCtrl"
                                    runat="server" MaxLength="9" NullText="请输入本次行驶里程" TabIndex="7" Width="200px">
                                    <ValidationSettings ErrorDisplayMode="ImageWithTooltip" RequiredField-ErrorText="请输入本次行驶里程"
                                        ErrorFrameStyle-CssClass="TableNoBorder">
                                        <RequiredField IsRequired="True" />
                                        <RegularExpression ErrorText="只能输入正整数" ValidationExpression="^\+?[1-9][0-9]*$" />
                                    </ValidationSettings>
                                    <NullTextStyle ForeColor="LightSteelBlue" />
                                </dx:ASPxTextBox>
                            </td>
                        </tr>
                        <tr>
                            <td style="width: 120px">
                                去向：
                            </td>
                            <td style="width: 250px">
                                <dx:ASPxTextBox ID="txt_Direction" ClientInstanceName="tbxDirectionCtrl" runat="server"
                                    MaxLength="250" NullText="请输入去向" TabIndex="8" Width="200px">
                                    <ValidationSettings ErrorDisplayMode="ImageWithTooltip" RequiredField-ErrorText="请输入去向"
                                        ErrorFrameStyle-CssClass="TableNoBorder">
                                        <RequiredField IsRequired="True" />
                                    </ValidationSettings>
                                    <NullTextStyle ForeColor="LightSteelBlue" />
                                </dx:ASPxTextBox>
                            </td>
                            <td style="width: 120px">
                                行车线路：
                            </td>
                            <td style="width: 250px">
                                <dx:ASPxTextBox ID="txt_DrivingLine" ClientInstanceName="tbxDrivingLineCtrl" runat="server"
                                    MaxLength="500" NullText="请输入行车线路" TabIndex="9" Width="200px">
                                    <ValidationSettings ErrorDisplayMode="ImageWithTooltip" RequiredField-ErrorText="请输入行车线路"
                                        ErrorFrameStyle-CssClass="TableNoBorder">
                                        <RequiredField IsRequired="True" />
                                    </ValidationSettings>
                                    <NullTextStyle ForeColor="LightSteelBlue" />
                                </dx:ASPxTextBox>
                            </td>
                        </tr>
                        <tr>
                            <td style="width: 120px">
                                编号：
                            </td>
                            <td style="width: 250px">
                                <dx:ASPxTextBox ID="txt_SN" ClientInstanceName="tbxSNCtrl" runat="server" MaxLength="50"
                                    NullText="请输入编号" TabIndex="10" Width="200px">
                                    <ValidationSettings ErrorDisplayMode="ImageWithTooltip" RequiredField-ErrorText="请输入编号"
                                        ErrorFrameStyle-CssClass="TableNoBorder">
                                        <RequiredField IsRequired="True" />
                                    </ValidationSettings>
                                    <NullTextStyle ForeColor="LightSteelBlue" />
                                </dx:ASPxTextBox>
                            </td>
                            <td style="width: 120px">
                                备注：
                            </td>
                            <td style="width: 250px">
                                <dx:ASPxTextBox ID="txt_Remarks" ClientInstanceName="tbxRemarksCtrl" runat="server"
                                    MaxLength="250" NullText="请输入备注" TabIndex="11" Width="200px">
                                    <ValidationSettings ErrorDisplayMode="ImageWithTooltip" RequiredField-ErrorText="请输入备注"
                                        ErrorFrameStyle-CssClass="TableNoBorder">
                                        <RequiredField IsRequired="True" />
                                    </ValidationSettings>
                                    <NullTextStyle ForeColor="LightSteelBlue" />
                                </dx:ASPxTextBox>
                            </td>
                        </tr>
                        <tr>
                            <td style="width: 120px">
                                登记时间：
                            </td>
                            <td style="width: 250px">
                                <dx:ASPxDateEdit ID="txt_RegisterTime" ClientInstanceName="deRegisterTimeCtrl" runat="server"
                                    TabIndex="12" NullText="请选择登记时间" Width="200px" Spacing="0">
                                    <ValidationSettings ErrorDisplayMode="ImageWithTooltip" RequiredField-ErrorText="请选择登记时间"
                                        ErrorFrameStyle-CssClass="TableNoBorder">
                                        <RequiredField IsRequired="True" />
                                    </ValidationSettings>
                                    <NullTextStyle ForeColor="LightSteelBlue" />
                                </dx:ASPxDateEdit>
                            </td>
                            <td style="width: 120px">
                                车牌号码：
                            </td>
                            <td style="width: 250px">
                                <dx:ASPxTextBox ID="txt_PlateNum" ClientInstanceName="tbxPlateNumCtrl" runat="server"
                                    MaxLength="20" NullText="请输入车牌号码" TabIndex="13" Width="200px">
                                    <ValidationSettings ErrorDisplayMode="ImageWithTooltip" RequiredField-ErrorText="请输入车牌号码"
                                        ErrorFrameStyle-CssClass="TableNoBorder">
                                        <RequiredField IsRequired="True" />
                                    </ValidationSettings>
                                    <NullTextStyle ForeColor="LightSteelBlue" />
                                </dx:ASPxTextBox>
                            </td>
                        </tr>
                        <tr>
                            <td style="width: 120px">
                                用车人：
                            </td>
                            <td style="width: 250px">
                                <dx:ASPxTextBox ID="txt_UserName" ClientInstanceName="tbxUserNameCtrl" runat="server"
                                    MaxLength="50" NullText="请输入用车人" TabIndex="14" Width="200px">
                                    <ValidationSettings ErrorDisplayMode="ImageWithTooltip" RequiredField-ErrorText="请输入用车人"
                                        ErrorFrameStyle-CssClass="TableNoBorder">
                                        <RequiredField IsRequired="True" />
                                    </ValidationSettings>
                                    <NullTextStyle ForeColor="LightSteelBlue" />
                                </dx:ASPxTextBox>
                            </td>
                            <td style="width: 120px">
                                用车单位：
                            </td>
                            <td style="width: 250px">
                                <dx:ASPxTextBox ID="txt_UserCompany" ClientInstanceName="tbxUserCompanyCtrl" runat="server"
                                    MaxLength="50" NullText="请输入用车单位" TabIndex="15" Width="200px">
                                    <ValidationSettings ErrorDisplayMode="ImageWithTooltip" RequiredField-ErrorText="请输入用车单位"
                                        ErrorFrameStyle-CssClass="TableNoBorder">
                                        <RequiredField IsRequired="True" />
                                    </ValidationSettings>
                                    <NullTextStyle ForeColor="LightSteelBlue" />
                                </dx:ASPxTextBox>
                            </td>
                        </tr>
                        <tr>
                            <td style="width: 120px">
                                人数：
                            </td>
                            <td style="width: 250px">
                                <dx:ASPxTextBox ID="txt_PeopleCount" ClientInstanceName="tbxPeopleCountCtrl" runat="server"
                                    MaxLength="4" NullText="请输入人数" TabIndex="16" Width="200px">
                                    <ValidationSettings ErrorDisplayMode="ImageWithTooltip" RequiredField-ErrorText="请输入人数"
                                        ErrorFrameStyle-CssClass="TableNoBorder">
                                        <RequiredField IsRequired="True" />
                                        <RegularExpression ErrorText="只能输入非负数字" ValidationExpression="^\d+(\.\d+)?$" />
                                    </ValidationSettings>
                                    <NullTextStyle ForeColor="LightSteelBlue" />
                                </dx:ASPxTextBox>
                            </td>
                            <td style="width: 120px">
                                驾驶员：
                            </td>
                            <td style="width: 250px">
                                <dx:ASPxTextBox ID="txt_Driver" ClientInstanceName="tbxDriverCtrl" runat="server"
                                    MaxLength="50" NullText="请输入驾驶员" TabIndex="17" Width="200px">
                                    <ValidationSettings ErrorDisplayMode="ImageWithTooltip" RequiredField-ErrorText="请输入驾驶员"
                                        ErrorFrameStyle-CssClass="TableNoBorder">
                                        <RequiredField IsRequired="True" />
                                    </ValidationSettings>
                                    <NullTextStyle ForeColor="LightSteelBlue" />
                                </dx:ASPxTextBox>
                            </td>
                        </tr>
                        <tr>
                            <td style="width: 120px">
                                用车事由：
                            </td>
                            <td style="width: 250px">
                                <dx:ASPxTextBox ID="txt_Cause" ClientInstanceName="tbxCauseCtrl" runat="server" MaxLength="250"
                                    NullText="请输入用车事由" TabIndex="18" Width="200px">
                                    <ValidationSettings ErrorDisplayMode="ImageWithTooltip" RequiredField-ErrorText="请输入用车事由"
                                        ErrorFrameStyle-CssClass="TableNoBorder">
                                        <RequiredField IsRequired="True" />
                                    </ValidationSettings>
                                    <NullTextStyle ForeColor="LightSteelBlue" />
                                </dx:ASPxTextBox>
                            </td>
                            <td style="width: 120px">
                                出发时间：
                            </td>
                            <td style="width: 250px">
                                <dx:ASPxDateEdit ID="txt_SendTime" ClientInstanceName="deSendTimeCtrl" runat="server"
                                    TabIndex="19" NullText="请选择出发时间" Width="200px" Spacing="0">
                                    <ValidationSettings ErrorDisplayMode="ImageWithTooltip" RequiredField-ErrorText="请选择出发时间"
                                        ErrorFrameStyle-CssClass="TableNoBorder">
                                        <RequiredField IsRequired="True" />
                                    </ValidationSettings>
                                    <NullTextStyle ForeColor="LightSteelBlue" />
                                </dx:ASPxDateEdit>
                            </td>
                        </tr>
                    </table>
                    <br />
                    <table class="TableNoBorder" style="width: 740px">
                        <tr>
                            <td colspan="2" />
                            <td align="left" style="margin-right: 20px; width: 100px">
                                <dx:ASPxButton ID="btnSave" runat="server" Text="保  存" Width="80px" AutoPostBack="false"
                                    TabIndex="20">
                                    <ClientSideEvents Click="function(s,e){
                            if(ASPxClientEdit.ValidateEditorsInContainer(null)){
                                cbSaveCtrl.PerformCallback();
                                lpSaveCtrl.Show();
                            }
                        }" />
                                </dx:ASPxButton>
                            </td>
                            <td align="left" style="margin-right: 20px; width: 100px">
                                <dx:ASPxButton ID="btnCancel" runat="server" Text="重  置" Width="80px" TabIndex="21">
                                    <ClientSideEvents Click="function(s,e){ASPxClientEdit.ClearEditorsInContainer(null);}" />
                                </dx:ASPxButton>
                            </td>
                        </tr>
                    </table>
                    <dx:ASPxCallback ID="cbSave" runat="server" ClientInstanceName="cbSaveCtrl" OnCallback="cbSave_Callback">
                        <ClientSideEvents CallbackComplete="function(s, e) {
                                if(s.cpIsSucceed == true){
                                    lpSaveCtrl.SetText('提交成功');
                                    window.setTimeout(function(){lpSaveCtrl.Hide();lpSaveCtrl.SetText('正在提交信息,请稍后...');},1500);
                                }else{
                                    lpSaveCtrl.SetText('提交失败');
                                    window.setTimeout(function(){lpSaveCtrl.Hide();lpSaveCtrl.SetText('正在提交信息,请稍后...');},1500);
                                }
                            }" />
                    </dx:ASPxCallback>
                    <dx:ASPxLoadingPanel ID="lpSave" runat="server" Text="正在提交信息,请稍后..." ClientInstanceName="lpSaveCtrl">
                    </dx:ASPxLoadingPanel>
                </div>
            </div>
        </div>
    </div>
    </form>
</body>
</html>
